#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
#define rep(i, a, b) for (int i = (a); i <= (b); i++)
#define per(i, a, b) for (int i = (a); i >= (b); i--)
#define endl '\n'
const int N = 2e5 + 5;

int w, h, n, m;

struct SegmentTree {
  struct Node {
    int cnt;
    int left, right, mx;
  };
  int n;
  vector<Node> tr;
  SegmentTree(int _n) : n(_n), tr(n << 2) { build(1, 0, n); }
  void pushup(int p) {
    int x = tr[p << 1].right + tr[p << 1 | 1].left;
    tr[p].cnt = tr[p << 1].cnt + tr[p << 1 | 1].cnt;
    tr[p].mx = max({tr[p << 1].mx, tr[p << 1 | 1].mx, x});
    if (tr[p << 1].cnt)
      tr[p].left = tr[p << 1].left;
    else
      tr[p].left = tr[p << 1].left + tr[p << 1 | 1].left;
    if (tr[p << 1 | 1].cnt)
      tr[p].right = tr[p << 1 | 1].right;
    else
      tr[p].right = tr[p << 1 | 1].right + tr[p << 1].right;
  }
  void build(int p, int l, int r) {
    if (l + 1 == r) {
      tr[p].cnt = 0;
      tr[p].left = tr[p].right = tr[p].mx = 1;
      return;
    }
    int mid = (l + r) >> 1;
    build(p << 1, l, mid);
    build(p << 1 | 1, mid, r);
    pushup(p);
  }
  void insert(int x) { insert(x, 1, 0, n); }
  void insert(int x, int p, int l, int r) {
    if (l + 1 == r) {
      tr[p].cnt = 1;
      tr[p].left = 0;
      tr[p].right = tr[p].mx = 1;
      return;
    }
    int mid = (l + r) >> 1;
    if (x < mid)
      insert(x, p << 1, l, mid);
    else
      insert(x, p << 1 | 1, mid, r);
    pushup(p);
  }
  int query() { return tr[1].mx; }
};

int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> w >> h >> n;
  SegmentTree trw(w), trh(h);
  while (n--) {
    char c;
    int x;
    cin >> c >> x;
    if (c == 'H')
      trh.insert(x);
    else
      trw.insert(x);
    cout << 1ll * trw.query() * trh.query() << endl;
  }
  return 0;
}